home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 January: Mac OS SDK / Dev.CD Jan 99 SDK1.toast / Development Kits / Interfaces&Libraries / Universal / Interfaces / AIncludes / FSM.a < prev    next >
Encoding:
Text File  |  1998-08-17  |  39.4 KB  |  1,274 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        FSM.a
  3. ;
  4. ;    Contains:    HFS External File System Interfaces.
  5. ;
  6. ;    Version:    Technology:    System 7.5
  7. ;                Release:    Universal Interfaces 3.2
  8. ;
  9. ;    Copyright:    © 1985-1998 by Apple Computer, Inc., all rights reserved
  10. ;
  11. ;    Bugs?:        For bug reports, consult the following page on
  12. ;                the World Wide Web:
  13. ;
  14. ;                    http://developer.apple.com/bugreporter/
  15. ;
  16. ;
  17.     IF &TYPE('__FSM__') = 'UNDEFINED' THEN
  18. __FSM__ SET 1
  19.  
  20.     IF &TYPE('__FILES__') = 'UNDEFINED' THEN
  21.     include 'Files.a'
  22.     ENDIF
  23.  
  24. ;  VolMount declarations are now in Files.≈ 
  25.  
  26. ; * Miscellaneous file system values not in Files.≈
  27.  
  28.  
  29. fsUsrCNID                        EQU        16                    ; First assignable directory or file number 
  30.                                                             ;    File system trap word attribute bits 
  31. kHFSBit                            EQU        9                    ; HFS call: bit 9 
  32. kHFSMask                        EQU        $0200
  33. kAsyncBit                        EQU        10                    ; Asynchronous call: bit 10 
  34. kAsyncMask                        EQU        $0400
  35.  
  36. ; * HFSCIProc selectCode values
  37. ; * Note: The trap attribute bits (the HFS bit and the asynchronous bit)
  38. ; * may be set in these selectCode values.
  39.  
  40.  
  41. kFSMOpen                        EQU        $A000
  42. kFSMClose                        EQU        $A001
  43. kFSMRead                        EQU        $A002
  44. kFSMWrite                        EQU        $A003
  45. kFSMGetVolInfo                    EQU        $A007
  46. kFSMCreate                        EQU        $A008
  47. kFSMDelete                        EQU        $A009
  48. kFSMOpenRF                        EQU        $A00A
  49. kFSMRename                        EQU        $A00B
  50. kFSMGetFileInfo                    EQU        $A00C
  51. kFSMSetFileInfo                    EQU        $A00D
  52. kFSMUnmountVol                    EQU        $A00E
  53. kFSMMountVol                    EQU        $A00F
  54. kFSMAllocate                    EQU        $A010
  55. kFSMGetEOF                        EQU        $A011
  56. kFSMSetEOF                        EQU        $A012
  57. kFSMFlushVol                    EQU        $A013
  58. kFSMGetVol                        EQU        $A014
  59. kFSMSetVol                        EQU        $A015
  60. kFSMEject                        EQU        $A017
  61. kFSMGetFPos                        EQU        $A018
  62. kFSMOffline                        EQU        $A035
  63. kFSMSetFilLock                    EQU        $A041
  64. kFSMRstFilLock                    EQU        $A042
  65. kFSMSetFilType                    EQU        $A043
  66. kFSMSetFPos                        EQU        $A044
  67. kFSMFlushFile                    EQU        $A045                ;    The File System HFSDispatch selectCodes 
  68. kFSMOpenWD                        EQU        $0001
  69. kFSMCloseWD                        EQU        $0002
  70. kFSMCatMove                        EQU        $0005
  71. kFSMDirCreate                    EQU        $0006
  72. kFSMGetWDInfo                    EQU        $0007
  73. kFSMGetFCBInfo                    EQU        $0008
  74. kFSMGetCatInfo                    EQU        $0009
  75. kFSMSetCatInfo                    EQU        $000A
  76. kFSMSetVolInfo                    EQU        $000B
  77. kFSMLockRng                        EQU        $0010
  78. kFSMUnlockRng                    EQU        $0011
  79. kFSMXGetVolInfo                    EQU        $0012
  80. kFSMCreateFileIDRef                EQU        $0014
  81. kFSMDeleteFileIDRef                EQU        $0015
  82. kFSMResolveFileIDRef            EQU        $0016
  83. kFSMExchangeFiles                EQU        $0017
  84. kFSMCatSearch                    EQU        $0018
  85. kFSMOpenDF                        EQU        $001A
  86. kFSMMakeFSSpec                    EQU        $001B                ;    The Desktop Manager HFSDispatch selectCodes 
  87. kFSMDTGetPath                    EQU        $0020
  88. kFSMDTCloseDown                    EQU        $0021
  89. kFSMDTAddIcon                    EQU        $0022
  90. kFSMDTGetIcon                    EQU        $0023
  91. kFSMDTGetIconInfo                EQU        $0024
  92. kFSMDTAddAPPL                    EQU        $0025
  93. kFSMDTRemoveAPPL                EQU        $0026
  94. kFSMDTGetAPPL                    EQU        $0027
  95. kFSMDTSetComment                EQU        $0028
  96. kFSMDTRemoveComment                EQU        $0029
  97. kFSMDTGetComment                EQU        $002A
  98. kFSMDTFlush                        EQU        $002B
  99. kFSMDTReset                        EQU        $002C
  100. kFSMDTGetInfo                    EQU        $002D
  101. kFSMDTOpenInform                EQU        $002E
  102. kFSMDTDelete                    EQU        $002F                ;    The AppleShare HFSDispatch selectCodes 
  103. kFSMGetVolParms                    EQU        $0030
  104. kFSMGetLogInInfo                EQU        $0031
  105. kFSMGetDirAccess                EQU        $0032
  106. kFSMSetDirAccess                EQU        $0033
  107. kFSMMapID                        EQU        $0034
  108. kFSMMapName                        EQU        $0035
  109. kFSMCopyFile                    EQU        $0036
  110. kFSMMoveRename                    EQU        $0037
  111. kFSMOpenDeny                    EQU        $0038
  112. kFSMOpenRFDeny                    EQU        $0039
  113. kFSMGetXCatInfo                    EQU        $003A
  114. kFSMGetVolMountInfoSize            EQU        $003F
  115. kFSMGetVolMountInfo                EQU        $0040
  116. kFSMVolumeMount                    EQU        $0041
  117. kFSMShare                        EQU        $0042
  118. kFSMUnShare                        EQU        $0043
  119. kFSMGetUGEntry                    EQU        $0044
  120. kFSMGetForeignPrivs                EQU        $0060
  121. kFSMSetForeignPrivs                EQU        $0061
  122. ; * UTDetermineVol status values
  123.  
  124.  
  125. dtmvError                        EQU        0                    ; param error 
  126. dtmvFullPathame                    EQU        1                    ; determined by full pathname 
  127. dtmvVRefNum                        EQU        2                    ; determined by volume refNum 
  128. dtmvWDRefNum                    EQU        3                    ; determined by working directory refNum 
  129. dtmvDriveNum                    EQU        4                    ; determined by drive number 
  130. dtmvDefault                        EQU        5                    ; determined by default volume 
  131.  
  132. ; * UTGetBlock options
  133.  
  134.  
  135. gbDefault                        EQU        0                    ; default value - read if not found 
  136.                                                             ;    bits and masks 
  137. gbReadBit                        EQU        0                    ; read block from disk (forced read) 
  138. gbReadMask                        EQU        $0001
  139. gbExistBit                        EQU        1                    ; get existing cache block 
  140. gbExistMask                        EQU        $0002
  141. gbNoReadBit                        EQU        2                    ; don't read block from disk if not found in cache 
  142. gbNoReadMask                    EQU        $0004
  143. gbReleaseBit                    EQU        3                    ; release block immediately after GetBlock 
  144. gbReleaseMask                    EQU        $0008
  145.  
  146. ; * UTReleaseBlock options
  147.  
  148.  
  149. rbDefault                        EQU        0                    ; default value - just mark the buffer not in-use 
  150.                                                             ;    bits and masks 
  151. rbWriteBit                        EQU        0                    ; force write buffer to disk 
  152. rbWriteMask                        EQU        $0001
  153. rbTrashBit                        EQU        1                    ; trash buffer contents after release 
  154. rbTrashMask                        EQU        $0002
  155. rbDirtyBit                        EQU        2                    ; mark buffer dirty 
  156. rbDirtyMask                        EQU        $0004
  157. rbFreeBit                        EQU        3                    ; free the buffer (save in the hash) 
  158. rbFreeMask                        EQU        $000A                ; rbFreeMask (rbFreeBit + rbTrashBit) works as rbTrash on < System 7.0 RamCache; on >= System 7.0, rbfreeMask overrides rbTrash 
  159.  
  160. ; * UTFlushCache options
  161.  
  162.  
  163. fcDefault                        EQU        0                    ; default value - pass this fcOption to just flush any dirty buffers 
  164.                                                             ;    bits and masks 
  165. fcTrashBit                        EQU        0                    ; (don't pass this as fcOption, use only for testing bit) 
  166. fcTrashMask                        EQU        $0001                ; pass this fcOption value to flush and trash cache blocks 
  167. fcFreeBit                        EQU        1                    ; (don't pass this as fcOption, use only for testing bit) 
  168. fcFreeMask                        EQU        $0003                ; pass this fcOption to flush and free cache blocks (Note: both fcTrash and fcFree bits are set) 
  169.  
  170. ; * UTCacheReadIP and UTCacheWriteIP cacheOption bits and masks are the ioPosMode
  171. ; * bits and masks in Files.x
  172.  
  173.  
  174. ; * Cache routine internal error codes
  175.  
  176.  
  177. chNoBuf                            EQU        1                    ; no free cache buffers (all in use) 
  178. chInUse                            EQU        2                    ; requested block in use 
  179. chnotfound                        EQU        3                    ; requested block not found 
  180. chNotInUse                        EQU        4                    ; block being released was not in use 
  181.  
  182. ; * FCBRec.fcbFlags bits
  183.  
  184.  
  185. fcbWriteBit                        EQU        0                    ; Data can be written to this file 
  186. fcbWriteMask                    EQU        $01
  187. fcbResourceBit                    EQU        1                    ; This file is a resource fork 
  188. fcbResourceMask                    EQU        $02
  189. fcbWriteLockedBit                EQU        2                    ; File has a locked byte range 
  190. fcbWriteLockedMask                EQU        $04
  191. fcbSharedWriteBit                EQU        4                    ; File is open for shared write access 
  192. fcbSharedWriteMask                EQU        $10
  193. fcbFileLockedBit                EQU        5                    ; File is locked (write-protected) 
  194. fcbFileLockedMask                EQU        $20
  195. fcbOwnClumpBit                    EQU        6                    ; File has clump size specified in FCB 
  196. fcbOwnClumpMask                    EQU        $40
  197. fcbModifiedBit                    EQU        7                    ; File has changed since it was last flushed 
  198. fcbModifiedMask                    EQU        $80
  199.  
  200. ; *    HFS Component Interface constants
  201.  
  202.  
  203. ; * compInterfMask bits specific to HFS component
  204.  
  205.  
  206. hfsCIDoesHFSBit                    EQU        23                    ; set if file system supports HFS calls 
  207. hfsCIDoesHFSMask                EQU        $00800000
  208. hfsCIDoesAppleShareBit            EQU        22                    ; set if AppleShare calls supported 
  209. hfsCIDoesAppleShareMask            EQU        $00400000
  210. hfsCIDoesDeskTopBit                EQU        21                    ; set if Desktop Database calls supported 
  211. hfsCIDoesDeskTopMask            EQU        $00200000
  212. hfsCIDoesDynamicLoadBit            EQU        20                    ; set if dynamically loading code resource 
  213. hfsCIDoesDynamicLoadMask        EQU        $00100000            ;        supported 
  214. hfsCIResourceLoadedBit            EQU        19                    ; set if code resource already loaded 
  215. hfsCIResourceLoadedMask            EQU        $00080000
  216. hfsCIHasHLL2PProcBit            EQU        18                    ; set if FFS' log2PhyProc and Extendfile proc 
  217. hfsCIHasHLL2PProcMask            EQU        $00040000            ; is written in a high level language. (i.e., uses Pascal calling convention) 
  218. hfsCIWantsDTSupportBit            EQU        17                    ; set if FFS wants the Mac OS's Desktop Manager code to handle 
  219. hfsCIWantsDTSupportMask            EQU        $00020000            ; all Desktop Manager requests to its volumes. 
  220.  
  221. ; *    Disk Initialization Component Interface constants
  222.  
  223.  
  224. ; * compInterfMask bits specific to Disk Initialization component
  225.  
  226.  
  227. diCIHasExtFormatParamsBit        EQU        18                    ; set if file system needs extended format 
  228. diCIHasExtFormatParamsMask        EQU        $00040000            ;        parameters 
  229. diCIHasMultiVolTypesBit            EQU        17                    ; set if file system supports more than one 
  230. diCIHasMultiVolTypesMask        EQU        $00020000            ;        volume type 
  231. diCIDoesSparingBit                EQU        16                    ; set if file system supports disk sparing 
  232. diCIDoesSparingMask                EQU        $00010000
  233. diCILiveBit                        EQU        0                    ; set if file system is candidate for current 
  234. diCILiveMask                    EQU        $00000001            ;        formatting operation (set by PACK2) 
  235.  
  236. ; * Disk Initialization Component Function selectors
  237.  
  238.  
  239. diCILoad                        EQU        1                    ; Make initialization code memory resident 
  240. diCIUnload                        EQU        2                    ; Make initialization code purgeable 
  241. diCIEvaluateSizeChoices            EQU        3                    ; Evaluate size choices 
  242. diCIExtendedZero                EQU        4                    ; Write an empty volume directory 
  243. diCIValidateVolName                EQU        5                    ; Validate volume name 
  244. diCIGetVolTypeInfo                EQU        6                    ; get volume type info 
  245. diCIGetFormatString                EQU        7                    ; get dialog format string 
  246. diCIGetExtFormatParams            EQU        8                    ; get extended format parameters 
  247. diCIGetDefectList                EQU        9                    ; return the defect list for the indicated disk - reserved for future use 
  248.  
  249. ; * Constants used in the DICIEvaluateSizeRec and FormatListRec
  250.  
  251.  
  252. diCIFmtListMax                    EQU        8                    ; maximum number of format list entries in DICIEvaluateSizeRec.numSizeEntries 
  253.                                                             ;    bits in FormatListRec.formatFlags: 
  254. diCIFmtFlagsValidBit            EQU        7                    ; set if sec, side, tracks valid 
  255. diCIFmtFlagsValidMask            EQU        $80
  256. diCIFmtFlagsCurrentBit            EQU        6                    ; set if current disk has this fmt 
  257. diCIFmtFlagsCurrentMask            EQU        $40                    ;    bits in FormatListRec.sizeListFlags: 
  258. diCISizeListOKBit                EQU        15                    ; set if this disk size usable 
  259. diCISizeListOKMask                EQU        $8000
  260.  
  261. ; * DICIGetFormatStringRec.stringKind format strings
  262.  
  263.  
  264. diCIAlternateFormatStr            EQU        1                    ; get alternate format  string (Balloon Help) 
  265. diCISizePresentationStr            EQU        2                    ; get size presentation string (for dialog) 
  266.  
  267. ; * Error codes returned by Disk Sparing
  268.  
  269.  
  270. diCIUserCancelErr                EQU        1                    ; user cancelled the disk init 
  271. diCICriticalSectorBadErr        EQU        20                    ; critical sectors are bad (hopeless)    
  272. diCISparingFailedErr            EQU        21                    ; disk cannot be spared 
  273. diCITooManyBadSectorsErr        EQU        22                    ; too many bad sectors 
  274. diCIUnknownVolTypeErr            EQU        23                    ; the volume type passed in diCIExtendedZero paramBlock is not supported 
  275. diCIVolSizeMismatchErr            EQU        24                    ; specified volume size doesn’t match with formatted disk size 
  276. diCIUnknownDICallErr            EQU        25                    ; bogus DI function call selector 
  277. diCINoSparingErr                EQU        26                    ; disk is bad but the target FS doesn't do disk sparing 
  278. diCINoExtendInfoErr                EQU        27                    ; missing file system specific extra parameter in diCIExtendedZero call 
  279. diCINoMessageTextErr            EQU        28                    ; missing message text in DIReformat call 
  280.  
  281. ; *    File System Manager constants
  282.  
  283.  
  284. ; * Miscellaneous constants used by FSM
  285.  
  286.  
  287. fsdVersion1                        EQU        1                    ; current version of FSD record 
  288. fsmIgnoreFSID                    EQU        $FFFE                ; this FSID should be ignored by the driver 
  289. fsmGenericFSID                    EQU        $FFFF                ; unknown foreign file system ID 
  290.  
  291. ; * compInterfMask bits common to all FSM components
  292.  
  293.  
  294. fsmComponentEnableBit            EQU        31                    ; set if FSM component interface is enabled 
  295. fsmComponentEnableMask            EQU        $80000000
  296. fsmComponentBusyBit                EQU        30                    ; set if FSM component interface is busy 
  297. fsmComponentBusyMask            EQU        $40000000
  298.  
  299. ; * Selectors for GetFSInfo
  300.  
  301.  
  302. fsmGetFSInfoByIndex                EQU        -1                    ; get fs info by index 
  303. fsmGetFSInfoByFSID                EQU        0                    ; get fs info by FSID 
  304. fsmGetFSInfoByRefNum            EQU        1                    ; get fs info by file/vol refnum 
  305.  
  306. ; * InformFSM messages
  307.  
  308.  
  309. fsmNopMessage                    EQU        0                    ; nop 
  310. fsmDrvQElChangedMessage            EQU        1                    ; DQE has changed 
  311. fsmGetFSIconMessage                EQU        2                    ; Get FFS's disk icon 
  312.  
  313. ; * Messages passed to the fileSystemCommProc
  314.  
  315.  
  316. ffsNopMessage                    EQU        0                    ; nop, should always return noErr 
  317. ffsGetIconMessage                EQU        1                    ; return disk icon and mask 
  318. ffsIDDiskMessage                EQU        2                    ; identify the about-to-be-mounted volume 
  319. ffsLoadMessage                    EQU        3                    ; load in the FFS 
  320. ffsUnloadMessage                EQU        4                    ; unload the FFS 
  321. ffsIDVolMountMessage            EQU        5                    ; identify a VolMountInfo record 
  322. ffsInformMessage                EQU        6                    ; FFS defined message 
  323. ffsGetIconInfoMessage            EQU        7
  324.  
  325. ; * Error codes from FSM functions
  326.  
  327.  
  328. fsmFFSNotFoundErr                EQU        -431                ; Foreign File system does not exist - new Pack2 could return this error too 
  329. fsmBusyFFSErr                    EQU        -432                ; File system is busy, cannot be removed 
  330. fsmBadFFSNameErr                EQU        -433                ; Name length not 1 <= length <= 31 
  331. fsmBadFSDLenErr                    EQU        -434                ; FSD size incompatible with current FSM vers 
  332. fsmDuplicateFSIDErr                EQU        -435                ; FSID already exists on InstallFS 
  333. fsmBadFSDVersionErr                EQU        -436                ; FSM version incompatible with FSD 
  334. fsmNoAlternateStackErr            EQU        -437                ; no alternate stack for HFS CI 
  335. fsmUnknownFSMMessageErr            EQU        -438                ; unknown message passed to FSM 
  336.  
  337. ; *    HFS Utility routine records
  338.  
  339.  
  340. ; * record used by UTGetPathComponentName
  341.  
  342. ParsePathRec            RECORD 0
  343. namePtr                     ds.l    1                ; offset: $0 (0)        ;  pathname to parse 
  344. startOffset                 ds.w    1                ; offset: $4 (4)        ;  where to start parsing 
  345. componentLength             ds.w    1                ; offset: $6 (6)        ;  the length of the pathname component parsed 
  346. moreName                 ds.b    1                ; offset: $8 (8)        ;  non-zero if there are more components after this one 
  347. foundDelimiter             ds.b    1                ; offset: $9 (9)        ;  non-zero if parsing stopped because a colon (:) delimiter was found 
  348. sizeof                     EQU *                    ; size:   $A (10)
  349.                         ENDR
  350. ; typedef struct ParsePathRec *            ParsePathRecPtr
  351.  
  352. WDCBRec                    RECORD 0
  353. wdVCBPtr                 ds.l    1                ; offset: $0 (0)        ;  Pointer to VCB of this working directory 
  354. wdDirID                     ds.l    1                ; offset: $4 (4)        ;  Directory ID number of this working directory 
  355. wdCatHint                 ds.l    1                ; offset: $8 (8)        ;  Hint for finding this working directory 
  356. wdProcID                 ds.l    1                ; offset: $C (12)        ;  Process that created this working directory 
  357. sizeof                     EQU *                    ; size:   $10 (16)
  358.                         ENDR
  359. ; typedef struct WDCBRec *                WDCBRecPtr
  360.  
  361. FCBRec                    RECORD 0
  362. fcbFlNm                     ds.l    1                ; offset: $0 (0)        ;  FCB file number. Non-zero marks FCB used 
  363. fcbFlags                 ds.b    1                ; offset: $4 (4)        ;  FCB flags 
  364. fcbTypByt                 ds.b    1                ; offset: $5 (5)        ;  File type byte 
  365. fcbSBlk                     ds.w    1                ; offset: $6 (6)        ;  File start block (in alloc size blks) 
  366. fcbEOF                     ds.l    1                ; offset: $8 (8)        ;  Logical length or EOF in bytes 
  367. fcbPLen                     ds.l    1                ; offset: $C (12)        ;  Physical file length in bytes 
  368. fcbCrPs                     ds.l    1                ; offset: $10 (16)        ;  Current position within file 
  369. fcbVPtr                     ds.l    1                ; offset: $14 (20)        ;  Pointer to the corresponding VCB 
  370. fcbBfAdr                 ds.l    1                ; offset: $18 (24)        ;  File's buffer address 
  371. fcbFlPos                 ds.w    1                ; offset: $1C (28)        ;  Directory block this file is in 
  372. ;  FCB Extensions for HFS 
  373. fcbClmpSize                 ds.l    1                ; offset: $1E (30)        ;  Number of bytes per clump 
  374. fcbBTCBPtr                 ds.l    1                ; offset: $22 (34)        ;  Pointer to B*-Tree control block for file 
  375. fcbExtRec                 ds.l    3                ; offset: $26 (38)        ;  First 3 file extents 
  376. fcbFType                 ds.l    1                ; offset: $32 (50)        ;  File's 4 Finder Type bytes 
  377. fcbCatPos                 ds.l    1                ; offset: $36 (54)        ;  Catalog hint for use on Close 
  378. fcbDirID                 ds.l    1                ; offset: $3A (58)        ;  Parent Directory ID 
  379. fcbCName                 ds        Str31            ; offset: $3E (62)        ;  CName of open file 
  380. sizeof                     EQU *                    ; size:   $5E (94)
  381.                         ENDR
  382. ; typedef struct FCBRec *                FCBRecPtr
  383.  
  384. ; *    HFS Component Interface records
  385.  
  386. HFSCIRec                RECORD 0
  387. compInterfMask             ds.l    1                ; offset: $0 (0)        ;  component flags 
  388. compInterfProc             ds.l    1                ; offset: $4 (4)        ;  pointer to file system call processing code 
  389. log2PhyProc                 ds.l    1                ; offset: $8 (8)        ;  pointer to Lg2PhysProc() code 
  390. stackTop                 ds.l    1                ; offset: $C (12)        ;  file system stack top 
  391. stackSize                 ds.l    1                ; offset: $10 (16)        ;  file system stack size 
  392. stackPtr                 ds.l    1                ; offset: $14 (20)        ;  current file system stack pointer 
  393. reserved3                 ds.l    1                ; offset: $18 (24)        ;  --reserved, must be zero-- 
  394. idSector                 ds.l    1                ; offset: $1C (28)        ;  Sector you need to ID a local volume. For networked volumes, this must be -1 
  395. reserved2                 ds.l    1                ; offset: $20 (32)        ;  --reserved, must be zero-- 
  396. reserved1                 ds.l    1                ; offset: $24 (36)        ;  --reserved, must be zero-- 
  397. sizeof                     EQU *                    ; size:   $28 (40)
  398.                         ENDR
  399. ; typedef struct HFSCIRec *                HFSCIRecPtr
  400.  
  401. ; *    Disk Initialization Component Interface records
  402.  
  403. DICIRec                    RECORD 0
  404. compInterfMask             ds.l    1                ; offset: $0 (0)        ;  component flags 
  405. compInterfProc             ds.l    1                ; offset: $4 (4)        ;  pointer to call processing code 
  406. maxVolNameLength         ds.w    1                ; offset: $8 (8)        ;  maximum length of your volume name 
  407. blockSize                 ds.w    1                ; offset: $A (10)        ;  your file system's block size 
  408. reserved3                 ds.l    1                ; offset: $C (12)        ;  --reserved, must be zero-- 
  409. reserved2                 ds.l    1                ; offset: $10 (16)        ;  --reserved, must be zero-- 
  410. reserved1                 ds.l    1                ; offset: $14 (20)        ;  --reserved, must be zero-- 
  411. sizeof                     EQU *                    ; size:   $18 (24)
  412.                         ENDR
  413. ; typedef struct DICIRec *                DICIRecPtr
  414.  
  415. ; * FormatListRec as returned by the .Sony disk driver's
  416. ; * Return Format List status call (csCode = 6).
  417. ; * If the status call to get this list for a drive is not
  418. ; * implemented by the driver, then a list with one entry
  419. ; * is contructed from the drive queue element for the drive.
  420.  
  421. FormatListRec            RECORD 0
  422. volSize                     ds.l    1                ; offset: $0 (0)        ;  disk capacity in SECTORs 
  423. formatFlags                 ds.b    1                ; offset: $4 (4)        ;  flags 
  424. sectorsPerTrack             ds.b    1                ; offset: $5 (5)        ;  sectors per track side 
  425. tracks                     ds.w    1                ; offset: $6 (6)        ;  number of tracks 
  426. sizeof                     EQU *                    ; size:   $8 (8)
  427.                         ENDR
  428. ; typedef struct FormatListRec *        FormatListRecPtr
  429.  
  430. ; * SizeListRec built from FormatListRecs as described above.
  431.  
  432. SizeListRec                RECORD 0
  433. sizeListFlags             ds.w    1                ; offset: $0 (0)        ;  flags as set by external file system 
  434. sizeEntry                 ds        FormatListRec    ; offset: $2 (2)        ;  disk driver format list record 
  435. sizeof                     EQU *                    ; size:   $A (10)
  436.                         ENDR
  437. ; typedef struct SizeListRec *            SizeListRecPtr
  438.  
  439. ; * paramBlock for the diCIEvaluateSize call
  440.  
  441. DICIEvaluateSizeRec        RECORD 0
  442. defaultSizeIndex         ds.w    1                ; offset: $0 (0)        ;  default size for this FS 
  443. numSizeEntries             ds.w    1                ; offset: $2 (2)        ;  number of size entries 
  444. driveNumber                 ds.w    1                ; offset: $4 (4)        ;  drive number 
  445. sizeListPtr                 ds.l    1                ; offset: $6 (6)        ;  ptr to size entry table 
  446. sectorSize                 ds.w    1                ; offset: $A (10)        ;  bytes per sector 
  447. sizeof                     EQU *                    ; size:   $C (12)
  448.                         ENDR
  449. ; typedef struct DICIEvaluateSizeRec *    DICIEvaluateSizeRecPtr
  450.  
  451. ; * paramBlock for the diCIExtendedZero call
  452.  
  453. DICIExtendedZeroRec        RECORD 0
  454. driveNumber                 ds.w    1                ; offset: $0 (0)        ;  drive number 
  455. volNamePtr                 ds.l    1                ; offset: $2 (2)        ;  ptr to volume name string 
  456. fsid                     ds.w    1                ; offset: $6 (6)        ;  file system ID 
  457. volTypeSelector             ds.w    1                ; offset: $8 (8)        ;  volume type selector, if supports more than 1 type 
  458. numDefectBlocks             ds.w    1                ; offset: $A (10)        ;  number of bad logical blocks 
  459. defectListSize             ds.w    1                ; offset: $C (12)        ;  size of the defect list buffer in bytes 
  460. defectListPtr             ds.l    1                ; offset: $E (14)        ;  pointer to defect list buffer 
  461. volSize                     ds.l    1                ; offset: $12 (18)        ;  size of volume in SECTORs 
  462. sectorSize                 ds.w    1                ; offset: $16 (22)        ;  bytes per sector 
  463. extendedInfoPtr             ds.l    1                ; offset: $18 (24)        ;  ptr to extended info 
  464. sizeof                     EQU *                    ; size:   $1C (28)
  465.                         ENDR
  466. ; typedef struct DICIExtendedZeroRec *    DICIExtendedZeroRecPtr
  467.  
  468. ; * paramBlock for the diCIValidateVolName call
  469.  
  470. DICIValidateVolNameRec    RECORD 0
  471. theChar                     ds.b    1                ; offset: $0 (0)        ;  the character to validate 
  472. hasMessageBuffer         ds.b    1                ; offset: $1 (1)        ;  false if no message 
  473. charOffset                 ds.w    1                ; offset: $2 (2)        ;  position of the current character (first char = 1) 
  474. messageBufferPtr         ds.l    1                ; offset: $4 (4)        ;  pointer to message buffer or nil 
  475. charByteType             ds.w    1                ; offset: $8 (8)        ;  theChar's byte type (smSingleByte, smFirstByte, or smLastByte) 
  476. sizeof                     EQU *                    ; size:   $A (10)
  477.                         ENDR
  478. ; typedef struct DICIValidateVolNameRec * DICIValidateVolNameRecPtr
  479.  
  480. ; * paramBlock for the diCIGetVolTypeInfo call
  481.  
  482. DICIGetVolTypeInfoRec    RECORD 0
  483. volSize                     ds.l    1                ; offset: $0 (0)        ;  size of volume in SECTORs 
  484. sectorSize                 ds.w    1                ; offset: $4 (4)        ;  bytes per sector 
  485. numVolTypes                 ds.w    1                ; offset: $6 (6)        ;  number of volume types supported 
  486. volTypesBuffer             ds.b    4 * Str31.sizeof ; offset: $8 (8)        ;  4 string buffers 
  487. sizeof                     EQU *                    ; size:   $88 (136)
  488.                         ENDR
  489. ; typedef struct DICIGetVolTypeInfoRec * DICIGetVolTypeInfoRecPtr
  490.  
  491. ; * paramBlock for the diCIGetFormatString call
  492.  
  493. DICIGetFormatStringRec    RECORD 0
  494. volSize                     ds.l    1                ; offset: $0 (0)        ;  volume size in SECTORs 
  495. sectorSize                 ds.w    1                ; offset: $4 (4)        ;  sector size 
  496. volTypeSelector             ds.w    1                ; offset: $6 (6)        ;  volume type selector 
  497. stringKind                 ds.w    1                ; offset: $8 (8)        ;  sub-function = type of string 
  498. stringBuffer             ds        Str255            ; offset: $A (10)        ;  string buffer 
  499. sizeof                     EQU *                    ; size:   $10A (266)
  500.                         ENDR
  501. ; typedef struct DICIGetFormatStringRec * DICIGetFormatStringRecPtr
  502.  
  503. ; * paramBlock for the diCIGetExtendedFormatParams call
  504.  
  505. DICIGetExtendedFormatRec RECORD 0
  506. driveNumber                 ds.w    1                ; offset: $0 (0)        ;  drive number 
  507. volTypeSelector             ds.w    1                ; offset: $2 (2)        ;  volume type selector or 0 
  508. volSize                     ds.l    1                ; offset: $4 (4)        ;  size of volume in SECTORs 
  509. sectorSize                 ds.w    1                ; offset: $8 (8)        ;  bytes per sector 
  510. fileSystemSpecPtr         ds.l    1                ; offset: $A (10)        ;  pointer to the foreign file system's FSSpec 
  511. extendedInfoPtr             ds.l    1                ; offset: $E (14)        ;  pointer to extended parameter structure 
  512. sizeof                     EQU *                    ; size:   $12 (18)
  513.                         ENDR
  514. ; typedef struct DICIGetExtendedFormatRec * DICIGetExtendedFormatRecPtr
  515.  
  516. ; *    File System Manager records
  517.  
  518.  
  519.  
  520.  
  521. FSDRec                    RECORD 0
  522. fsdLink                     ds.l    1                ; offset: $0 (0)        ;  ptr to next 
  523. fsdLength                 ds.w    1                ; offset: $4 (4)        ;  length of this FSD in BYTES 
  524. fsdVersion                 ds.w    1                ; offset: $6 (6)        ;  version number 
  525. fileSystemFSID             ds.w    1                ; offset: $8 (8)        ;  file system id 
  526. fileSystemName             ds        Str31            ; offset: $A (10)        ;  file system name 
  527. fileSystemSpec             ds        FSSpec            ; offset: $2A (42)        ;  foreign file system's FSSpec 
  528. fileSystemGlobalsPtr     ds.l    1                ; offset: $70 (112)        ;  ptr to file system globals 
  529. fileSystemCommProc         ds.l    1                ; offset: $74 (116)        ;  communication proc with the FFS 
  530. reserved3                 ds.l    1                ; offset: $78 (120)        ;  --reserved, must be zero-- 
  531. reserved2                 ds.l    1                ; offset: $7C (124)        ;  --reserved, must be zero-- 
  532. reserved1                 ds.l    1                ; offset: $80 (128)        ;  --reserved, must be zero-- 
  533. fsdHFSCI                 ds        HFSCIRec        ; offset: $84 (132)        ;  HFS component interface    
  534. fsdDICI                     ds        DICIRec            ; offset: $AC (172)        ;  Disk Initialization component interface 
  535. sizeof                     EQU *                    ; size:   $C4 (196)
  536.                         ENDR
  537. ; typedef struct FSDRec *                FSDRecPtr
  538.  
  539. FSMGetIconInfoRec        RECORD 0
  540. theIcon                     ds.l    32                ; offset: $0 (0)        ;  The ICN# structure 
  541. theMask                     ds.l    32                ; offset: $80 (128)        ;  The mask for the icon above 
  542. whereStr                 ds        Str255            ; offset: $100 (256)
  543. sizeof                     EQU *                    ; size:   $200 (512)
  544.                         ENDR
  545. ; typedef struct FSMGetIconInfoRec *    FSMGetIconInfoRecPtr
  546.  
  547. ; * paramBlock for ffsGetIconMessage and fsmGetFSIconMessage
  548.  
  549. FSMGetIconRec            RECORD 0
  550. refNum                     ds.w    1                ; offset: $0 (0)        ;  target drive num or volume refnum 
  551. iconBufferPtr             ds.l    1                ; offset: $2 (2)        ;  pointer to icon buffer 
  552. requestSize                 ds.l    1                ; offset: $6 (6)        ;  requested size of the icon buffer 
  553. actualSize                 ds.l    1                ; offset: $A (10)        ;  actual size of the icon data returned 
  554. iconType                 ds.b    1                ; offset: $E (14)        ;  kind of icon 
  555. isEjectable                 ds.b    1                ; offset: $F (15)        ;  true if the device is ejectable 
  556. driveQElemPtr             ds.l    1                ; offset: $10 (16)        ;  pointer to DQE 
  557. fileSystemSpecPtr         ds.l    1                ; offset: $14 (20)        ;  pointer to foreign file system's FSSpec 
  558. reserved1                 ds.l    1                ; offset: $18 (24)        ;  --reserved, must be zero-- 
  559. sizeof                     EQU *                    ; size:   $1C (28)
  560.                         ENDR
  561. ; typedef struct FSMGetIconRec *        FSMGetIconRecPtr
  562.  
  563. ; *    HFS Utility routine prototypes
  564.  
  565. ;
  566. ; pascal OSErr UTAllocateFCB(short *fileRefNum, FCBRecPtr *fileCtrlBlockPtr)
  567. ;
  568.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  569.         Macro
  570.         _UTAllocateFCB
  571.             moveq               #0,D0
  572.             dc.w                $A824
  573.         EndM
  574.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  575.         IMPORT_CFM_FUNCTION UTAllocateFCB
  576.     ENDIF
  577.  
  578. ;
  579. ; pascal OSErr UTReleaseFCB(short fileRefNum)
  580. ;
  581.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  582.         Macro
  583.         _UTReleaseFCB
  584.             moveq               #1,D0
  585.             dc.w                $A824
  586.         EndM
  587.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  588.         IMPORT_CFM_FUNCTION UTReleaseFCB
  589.     ENDIF
  590.  
  591. ;
  592. ; pascal OSErr UTLocateFCB(VCBPtr volCtrlBlockPtr, unsigned long fileNum, StringPtr namePtr, short *fileRefNum, FCBRecPtr *fileCtrlBlockPtr)
  593. ;
  594.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  595.         Macro
  596.         _UTLocateFCB
  597.             moveq               #2,D0
  598.             dc.w                $A824
  599.         EndM
  600.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  601.         IMPORT_CFM_FUNCTION UTLocateFCB
  602.     ENDIF
  603.  
  604. ;
  605. ; pascal OSErr UTLocateNextFCB(VCBPtr volCtrlBlockPtr, unsigned long fileNum, StringPtr namePtr, short *fileRefNum, FCBRecPtr *fileCtrlBlockPtr)
  606. ;
  607.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  608.         Macro
  609.         _UTLocateNextFCB
  610.             moveq               #3,D0
  611.             dc.w                $A824
  612.         EndM
  613.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  614.         IMPORT_CFM_FUNCTION UTLocateNextFCB
  615.     ENDIF
  616.  
  617. ;
  618. ; pascal OSErr UTIndexFCB(VCBPtr volCtrlBlockPtr, short *fileRefNum, FCBRecPtr *fileCtrlBlockPtr)
  619. ;
  620.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  621.         Macro
  622.         _UTIndexFCB
  623.             moveq               #4,D0
  624.             dc.w                $A824
  625.         EndM
  626.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  627.         IMPORT_CFM_FUNCTION UTIndexFCB
  628.     ENDIF
  629.  
  630. ;
  631. ; pascal OSErr UTResolveFCB(short fileRefNum, FCBRecPtr *fileCtrlBlockPtr)
  632. ;
  633.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  634.         Macro
  635.         _UTResolveFCB
  636.             moveq               #5,D0
  637.             dc.w                $A824
  638.         EndM
  639.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  640.         IMPORT_CFM_FUNCTION UTResolveFCB
  641.     ENDIF
  642.  
  643. ;
  644. ; pascal OSErr UTAllocateVCB(unsigned short *sysVCBLength, VCBPtr *volCtrlBlockPtr, unsigned short addSize)
  645. ;
  646.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  647.         Macro
  648.         _UTAllocateVCB
  649.             moveq               #6,D0
  650.             dc.w                $A824
  651.         EndM
  652.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  653.         IMPORT_CFM_FUNCTION UTAllocateVCB
  654.     ENDIF
  655.  
  656. ;
  657. ; pascal OSErr UTAddNewVCB(short driveNum, short *vRefNum, VCBPtr volCtrlBlockPtr)
  658. ;
  659.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  660.         Macro
  661.         _UTAddNewVCB
  662.             moveq               #7,D0
  663.             dc.w                $A824
  664.         EndM
  665.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  666.         IMPORT_CFM_FUNCTION UTAddNewVCB
  667.     ENDIF
  668.  
  669. ;
  670. ; pascal OSErr UTDisposeVCB(VCBPtr volCtrlBlockPtr)
  671. ;
  672.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  673.         Macro
  674.         _UTDisposeVCB
  675.             moveq               #8,D0
  676.             dc.w                $A824
  677.         EndM
  678.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  679.         IMPORT_CFM_FUNCTION UTDisposeVCB
  680.     ENDIF
  681.  
  682. ;
  683. ; pascal OSErr UTLocateVCBByRefNum(short refNum, short *vRefNum, VCBPtr *volCtrlBlockPtr)
  684. ;
  685.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  686.         Macro
  687.         _UTLocateVCBByRefNum
  688.             moveq               #9,D0
  689.             dc.w                $A824
  690.         EndM
  691.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  692.         IMPORT_CFM_FUNCTION UTLocateVCBByRefNum
  693.     ENDIF
  694.  
  695. ;
  696. ; pascal OSErr UTLocateVCBByName(StringPtr namePtr, short *moreMatches, short *vRefNum, VCBPtr *volCtrlBlockPtr)
  697. ;
  698.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  699.         Macro
  700.         _UTLocateVCBByName
  701.             moveq               #10,D0
  702.             dc.w                $A824
  703.         EndM
  704.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  705.         IMPORT_CFM_FUNCTION UTLocateVCBByName
  706.     ENDIF
  707.  
  708. ;
  709. ; pascal OSErr UTLocateNextVCB(StringPtr namePtr, short *moreMatches, short *vRefNum, VCBPtr *volCtrlBlockPtr)
  710. ;
  711.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  712.         Macro
  713.         _UTLocateNextVCB
  714.             moveq               #11,D0
  715.             dc.w                $A824
  716.         EndM
  717.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  718.         IMPORT_CFM_FUNCTION UTLocateNextVCB
  719.     ENDIF
  720.  
  721. ;
  722. ; pascal OSErr UTAllocateWDCB(WDPBPtr paramBlock)
  723. ;
  724.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  725.         Macro
  726.         _UTAllocateWDCB
  727.             moveq               #12,D0
  728.             dc.w                $A824
  729.         EndM
  730.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  731.         IMPORT_CFM_FUNCTION UTAllocateWDCB
  732.     ENDIF
  733.  
  734. ;
  735. ; pascal OSErr UTReleaseWDCB(short wdRefNum)
  736. ;
  737.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  738.         Macro
  739.         _UTReleaseWDCB
  740.             moveq               #13,D0
  741.             dc.w                $A824
  742.         EndM
  743.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  744.         IMPORT_CFM_FUNCTION UTReleaseWDCB
  745.     ENDIF
  746.  
  747. ;
  748. ; pascal OSErr UTResolveWDCB(long procID, short wdIndex, short wdRefNum, WDCBRecPtr *wdCtrlBlockPtr)
  749. ;
  750.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  751.         Macro
  752.         _UTResolveWDCB
  753.             moveq               #14,D0
  754.             dc.w                $A824
  755.         EndM
  756.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  757.         IMPORT_CFM_FUNCTION UTResolveWDCB
  758.     ENDIF
  759.  
  760. ;
  761. ; pascal OSErr UTFindDrive(short driveNum, DrvQElPtr *driveQElementPtr)
  762. ;
  763.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  764.         Macro
  765.         _UTFindDrive
  766.             moveq               #15,D0
  767.             dc.w                $A824
  768.         EndM
  769.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  770.         IMPORT_CFM_FUNCTION UTFindDrive
  771.     ENDIF
  772.  
  773. ;
  774. ; pascal OSErr UTAdjustEOF(short fileRefNum)
  775. ;
  776.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  777.         Macro
  778.         _UTAdjustEOF
  779.             moveq               #16,D0
  780.             dc.w                $A824
  781.         EndM
  782.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  783.         IMPORT_CFM_FUNCTION UTAdjustEOF
  784.     ENDIF
  785.  
  786. ;
  787. ; pascal OSErr UTSetDefaultVol(long nodeHint, unsigned long dirID, short refNum)
  788. ;
  789.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  790.         Macro
  791.         _UTSetDefaultVol
  792.             moveq               #17,D0
  793.             dc.w                $A824
  794.         EndM
  795.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  796.         IMPORT_CFM_FUNCTION UTSetDefaultVol
  797.     ENDIF
  798.  
  799. ;
  800. ; pascal OSErr UTGetDefaultVol(WDPBPtr paramBlock)
  801. ;
  802.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  803.         Macro
  804.         _UTGetDefaultVol
  805.             moveq               #18,D0
  806.             dc.w                $A824
  807.         EndM
  808.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  809.         IMPORT_CFM_FUNCTION UTGetDefaultVol
  810.     ENDIF
  811.  
  812. ;
  813. ; pascal OSErr UTEjectVol(VCBPtr volCtrlBlockPtr)
  814. ;
  815.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  816.         Macro
  817.         _UTEjectVol
  818.             moveq               #43,D0
  819.             dc.w                $A824
  820.         EndM
  821.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  822.         IMPORT_CFM_FUNCTION UTEjectVol
  823.     ENDIF
  824.  
  825. ;
  826. ; pascal OSErr UTCheckWDRefNum(short wdRefNum)
  827. ;
  828.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  829.         Macro
  830.         _UTCheckWDRefNum
  831.             moveq               #19,D0
  832.             dc.w                $A824
  833.         EndM
  834.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  835.         IMPORT_CFM_FUNCTION UTCheckWDRefNum
  836.     ENDIF
  837.  
  838. ;
  839. ; pascal OSErr UTCheckFileRefNum(short fileRefNum)
  840. ;
  841.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  842.         Macro
  843.         _UTCheckFileRefNum
  844.             moveq               #20,D0
  845.             dc.w                $A824
  846.         EndM
  847.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  848.         IMPORT_CFM_FUNCTION UTCheckFileRefNum
  849.     ENDIF
  850.  
  851. ;
  852. ; pascal OSErr UTCheckVolRefNum(short vRefNum)
  853. ;
  854.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  855.         Macro
  856.         _UTCheckVolRefNum
  857.             moveq               #21,D0
  858.             dc.w                $A824
  859.         EndM
  860.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  861.         IMPORT_CFM_FUNCTION UTCheckVolRefNum
  862.     ENDIF
  863.  
  864. ;
  865. ; pascal OSErr UTCheckPermission(VCBPtr volCtrlBlockPtr, short *modByte, unsigned long fileNum, ParmBlkPtr paramBlock)
  866. ;
  867.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  868.         Macro
  869.         _UTCheckPermission
  870.             moveq               #22,D0
  871.             dc.w                $A824
  872.         EndM
  873.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  874.         IMPORT_CFM_FUNCTION UTCheckPermission
  875.     ENDIF
  876.  
  877. ;
  878. ; pascal OSErr UTCheckVolOffline(short vRefNum)
  879. ;
  880.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  881.         Macro
  882.         _UTCheckVolOffline
  883.             moveq               #23,D0
  884.             dc.w                $A824
  885.         EndM
  886.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  887.         IMPORT_CFM_FUNCTION UTCheckVolOffline
  888.     ENDIF
  889.  
  890. ;
  891. ; pascal OSErr UTCheckVolModifiable(short vRefNum)
  892. ;
  893.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  894.         Macro
  895.         _UTCheckVolModifiable
  896.             moveq               #24,D0
  897.             dc.w                $A824
  898.         EndM
  899.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  900.         IMPORT_CFM_FUNCTION UTCheckVolModifiable
  901.     ENDIF
  902.  
  903. ;
  904. ; pascal OSErr UTCheckFileModifiable(short fileRefNum)
  905. ;
  906.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  907.         Macro
  908.         _UTCheckFileModifiable
  909.             moveq               #25,D0
  910.             dc.w                $A824
  911.         EndM
  912.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  913.         IMPORT_CFM_FUNCTION UTCheckFileModifiable
  914.     ENDIF
  915.  
  916. ;
  917. ; pascal OSErr UTCheckDirBusy(VCBPtr volCtrlBlockPtr, unsigned long dirID)
  918. ;
  919.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  920.         Macro
  921.         _UTCheckDirBusy
  922.             moveq               #26,D0
  923.             dc.w                $A824
  924.         EndM
  925.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  926.         IMPORT_CFM_FUNCTION UTCheckDirBusy
  927.     ENDIF
  928.  
  929. ;
  930. ; pascal OSErr UTParsePathname(short *volNamelength, StringPtr namePtr)
  931. ;
  932.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  933.         Macro
  934.         _UTParsePathname
  935.             moveq               #27,D0
  936.             dc.w                $A824
  937.         EndM
  938.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  939.         IMPORT_CFM_FUNCTION UTParsePathname
  940.     ENDIF
  941.  
  942. ;
  943. ; pascal OSErr UTGetPathComponentName(ParsePathRecPtr parseRec)
  944. ;
  945.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  946.         Macro
  947.         _UTGetPathComponentName
  948.             moveq               #28,D0
  949.             dc.w                $A824
  950.         EndM
  951.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  952.         IMPORT_CFM_FUNCTION UTGetPathComponentName
  953.     ENDIF
  954.  
  955. ;
  956. ; pascal OSErr UTDetermineVol(ParmBlkPtr paramBlock, short *status, short *moreMatches, short *vRefNum, VCBPtr *volCtrlBlockPtr)
  957. ;
  958.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  959.         Macro
  960.         _UTDetermineVol
  961.             moveq               #29,D0
  962.             dc.w                $A824
  963.         EndM
  964.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  965.         IMPORT_CFM_FUNCTION UTDetermineVol
  966.     ENDIF
  967.  
  968. ;
  969. ; pascal OSErr UTGetBlock(short refNum, void *log2PhyProc, unsigned long blockNum, short gbOption, Ptr *buffer)
  970. ;
  971.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  972.         Macro
  973.         _UTGetBlock
  974.             moveq               #31,D0
  975.             dc.w                $A824
  976.         EndM
  977.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  978.         IMPORT_CFM_FUNCTION UTGetBlock
  979.     ENDIF
  980.  
  981. ;
  982. ; pascal OSErr UTReleaseBlock(Ptr buffer, short rbOption)
  983. ;
  984.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  985.         Macro
  986.         _UTReleaseBlock
  987.             moveq               #32,D0
  988.             dc.w                $A824
  989.         EndM
  990.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  991.         IMPORT_CFM_FUNCTION UTReleaseBlock
  992.     ENDIF
  993.  
  994. ;
  995. ; pascal OSErr UTFlushCache(short refNum, short fcOption)
  996. ;
  997.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  998.         Macro
  999.         _UTFlushCache
  1000.             moveq               #33,D0
  1001.             dc.w                $A824
  1002.         EndM
  1003.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1004.         IMPORT_CFM_FUNCTION UTFlushCache
  1005.     ENDIF
  1006.  
  1007. ;
  1008. ; pascal OSErr UTMarkDirty(Ptr buffer)
  1009. ;
  1010.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1011.         Macro
  1012.         _UTMarkDirty
  1013.             moveq               #35,D0
  1014.             dc.w                $A824
  1015.         EndM
  1016.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1017.         IMPORT_CFM_FUNCTION UTMarkDirty
  1018.     ENDIF
  1019.  
  1020. ;
  1021. ; pascal OSErr UTTrashVolBlocks(VCBPtr volCtrlBlockPtr)
  1022. ;
  1023.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1024.         Macro
  1025.         _UTTrashVolBlocks
  1026.             moveq               #36,D0
  1027.             dc.w                $A824
  1028.         EndM
  1029.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1030.         IMPORT_CFM_FUNCTION UTTrashVolBlocks
  1031.     ENDIF
  1032.  
  1033. ;
  1034. ; pascal OSErr UTTrashFileBlocks(VCBPtr volCtrlBlockPtr, unsigned long fileNum)
  1035. ;
  1036.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1037.         Macro
  1038.         _UTTrashFileBlocks
  1039.             moveq               #37,D0
  1040.             dc.w                $A824
  1041.         EndM
  1042.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1043.         IMPORT_CFM_FUNCTION UTTrashFileBlocks
  1044.     ENDIF
  1045.  
  1046. ;
  1047. ; pascal OSErr UTTrashBlocks(unsigned long beginPosition, unsigned long byteCount, VCBPtr volCtrlBlockPtr, short fileRefNum, short tbOption)
  1048. ;
  1049.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1050.         Macro
  1051.         _UTTrashBlocks
  1052.             moveq               #38,D0
  1053.             dc.w                $A824
  1054.         EndM
  1055.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1056.         IMPORT_CFM_FUNCTION UTTrashBlocks
  1057.     ENDIF
  1058.  
  1059. ;
  1060. ; pascal OSErr UTCacheReadIP(void *log2PhyProc, unsigned long filePosition, Ptr ioBuffer, short fileRefNum, unsigned long reqCount, unsigned long *actCount, short cacheOption)
  1061. ;
  1062.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1063.         Macro
  1064.         _UTCacheReadIP
  1065.             moveq               #39,D0
  1066.             dc.w                $A824
  1067.         EndM
  1068.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1069.         IMPORT_CFM_FUNCTION UTCacheReadIP
  1070.     ENDIF
  1071.  
  1072. ;
  1073. ; pascal OSErr UTCacheWriteIP(void *log2PhyProc, unsigned long filePosition, Ptr ioBuffer, short fileRefNum, unsigned long reqCount, unsigned long *actCount, short cacheOption)
  1074. ;
  1075.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1076.         Macro
  1077.         _UTCacheWriteIP
  1078.             moveq               #40,D0
  1079.             dc.w                $A824
  1080.         EndM
  1081.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1082.         IMPORT_CFM_FUNCTION UTCacheWriteIP
  1083.     ENDIF
  1084.  
  1085. ;
  1086. ; pascal OSErr UTBlockInFQHashP(short vRefNum, unsigned long diskBlock)
  1087. ;
  1088.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1089.         Macro
  1090.         _UTBlockInFQHashP
  1091.             moveq               #44,D0
  1092.             dc.w                $A824
  1093.         EndM
  1094.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1095.         IMPORT_CFM_FUNCTION UTBlockInFQHashP
  1096.     ENDIF
  1097.  
  1098. ;
  1099. ; pascal OSErr UTVolCacheReadIP(VCBPtr volCtrlBlockPtr, unsigned long blockPosition, Ptr ioBuffer, unsigned long reqCount, unsigned long *actCount, short cacheOption)
  1100. ;
  1101.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1102.         Macro
  1103.         _UTVolCacheReadIP
  1104.             moveq               #52,D0
  1105.             dc.w                $A824
  1106.         EndM
  1107.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1108.         IMPORT_CFM_FUNCTION UTVolCacheReadIP
  1109.     ENDIF
  1110.  
  1111. ;
  1112. ; pascal OSErr UTVolCacheWriteIP(VCBPtr volCtrlBlockPtr, unsigned long blockPosition, Ptr ioBuffer, unsigned long reqCount, unsigned long *actCount, short cacheOption)
  1113. ;
  1114.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1115.         Macro
  1116.         _UTVolCacheWriteIP
  1117.             moveq               #53,D0
  1118.             dc.w                $A824
  1119.         EndM
  1120.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1121.         IMPORT_CFM_FUNCTION UTVolCacheWriteIP
  1122.     ENDIF
  1123.  
  1124.  
  1125.  
  1126. ; *    File System Manager call prototypes
  1127.  
  1128. ;
  1129. ; pascal OSErr InstallFS(FSDRecPtr fsdPtr)
  1130. ;
  1131.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1132.         ; parameters:
  1133.         ;    fsdPtr          => A0
  1134.         ; returns:
  1135.         ;    OSErr           <= D0
  1136.         Macro
  1137.         _InstallFS
  1138.             moveq               #0,D0
  1139.             dc.w                $A0AC
  1140.         EndM
  1141.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1142.         IMPORT_CFM_FUNCTION InstallFS
  1143.     ENDIF
  1144.  
  1145. ;
  1146. ; pascal OSErr RemoveFS(short fsid)
  1147. ;
  1148.     IF TARGET_OS_MAC ** TARGET_CPU_68K ** ¬ TARGET_RT_MAC_CFM THEN
  1149.         ; parameters:
  1150.         ;    fsid            => A0
  1151.         ; returns:
  1152.         ;    OSErr           <= D0
  1153.         Macro
  1154.         _RemoveFS
  1155.             moveq               #1,D0
  1156.             dc.w                $A0AC
  1157.         EndM
  1158.     ELSEIF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1159.         IMPORT_CFM_FUNCTION RemoveFS
  1160.     ENDIF
  1161.  
  1162. ;
  1163. ; pascal OSErr SetFSInfo(short fsid, short bufSize, FSDRecPtr fsdPtr)
  1164. ;
  1165.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1166.         IMPORT_CFM_FUNCTION SetFSInfo
  1167.     ENDIF
  1168.  
  1169. ;
  1170. ; pascal OSErr GetFSInfo(short selector, short key, short *bufSize, FSDRecPtr fsdPtr)
  1171. ;
  1172.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1173.         IMPORT_CFM_FUNCTION GetFSInfo
  1174.     ENDIF
  1175.  
  1176. ;
  1177. ; pascal OSErr InformFSM(short theMessage, void *paramBlock)
  1178. ;
  1179.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1180.         IMPORT_CFM_FUNCTION InformFSM
  1181.     ENDIF
  1182.  
  1183. ;
  1184. ; pascal OSErr InformFFS(short fsid, void *paramBlock)
  1185. ;
  1186.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  1187.         IMPORT_CFM_FUNCTION InformFFS
  1188.     ENDIF
  1189.  
  1190.  
  1191.  
  1192.     ENDIF ; __FSM__ 
  1193.  
  1194.